package com.zhiyu.service;

import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.zhiyu.common.BaseService;
import com.zhiyu.mapper.FlowerWoodMapper;
import com.zhiyu.pojo.FlowerWood;
import com.zhiyu.pojo.Products;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class FlowerWoodService extends BaseService<FlowerWoodMapper, FlowerWood> {
    public PageInfo<FlowerWood> getFlowerWoodByName(FlowerWood flowerWood) {
        PageHelper.startPage(flowerWood.getPageNum(), flowerWood.getPageSize());
        List<FlowerWood> list = mapper.selectFlowerWoodByName(flowerWood.getWoodName());
        return new PageInfo<>(list);
    }
}